#include <bits/stdc++.h>
#include <bits/extc++.h>
using namespace std;

using vi = vector<int>;


int main() {
#ifndef ONLINE_JUDGE
    freopen("z.txt", "r", stdin);
#endif
    ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
    int n; cin >> n;
    int ans = 0;
    for(int i=0;i<n;++i){
        int a, b, c; cin >> a >> b >> c;
        if(a + b + c >= 100) ++ ans;
    }
    cout << ans << endl;
    return 0;
}